﻿// <copyright file="DemoBluePlugIn.cs" company="Pelican Design &amp; Development">
//      Copyright (c) Pelican Design &amp; Development. All Rights Reserved.
// </copyright>

namespace BluePlugIn
{
    /// <summary>
    /// Sample blugin with a demo of direct, prohibited, file manipulation.
    /// </summary>
    public class DemoBluePlugIn : AppDomains.CommonPlugIn
    {
        /// <summary>
        /// Cached control.
        /// </summary>
        private BlueUserControl cachedBlueControl;

        /// <summary>
        /// Friendly name of the plugin.
        /// </summary>
        public override string Name
        {
            get { return "Blue as a sky"; }
        }

        /// <summary>
        /// A cached control to add to the window.
        /// </summary>
        public override System.Windows.Controls.UserControl MainControl
        {
            get
            {
                if (this.cachedBlueControl == null)
                {
                    this.cachedBlueControl = new BlueUserControl();
                }

                return this.cachedBlueControl;
            }
        }
    }
}
